TARGET       = fb_sdl
LIBS         = server env
REQUIRES     = linux sdl
SRC_CC       = fb_sdl.cc input.cc
INC_DIR     += /usr/include

#
# libSDL requires quite a lot of libc functions
# that we do not provide in our cxx library.
# Therefore, we use the host libc for building.
# We only need to include the new and delete
# operators from our cxx library because these
# are required by the Genode frameworks.
#

SRC_CC      += new_delete.cc
EXT_OBJECTS += -lSDLmain -lSDL

#
# SDL on Darwin needs to be linked against the Cocoa framework
#
ifeq ($(shell uname),Darwin)
EXT_OBJECTS += -framework Cocoa
endif

vpath new_delete.cc $(BASE_DIR)/src/base/cxx
